#include "StdAfx.h"
#include "VTreeItemType.h"

// VTreeItemType //////////////////////////////////////////////////////////////

//
QString VTreeItemType::enumToDisplay(Enum e)
{
	struct VMap
	{
		QMap<Enum,QString> map;

		VMap()
		{
			map[unknown]		=	"unknown";
			map[catalog]		= "catalog";
			map[table]			=	"table";
			map[primaryKey]	= "primary key";
			map[sReference]	= "s reference";
			map[mReference]	= "m reference";
			map[integer]		= "integer";
			map[string]			= "string";
		}
	};
	static VMap m;
	return m.map[e];
}
